# -*- coding: utf-8 -*-
"""
@Time : 2024/3/1 8:51 PM
@Author: imamhusan
@Des: 用户模型
"""
from tortoise import Model, fields


class User(Model):
    username = fields.CharField(max_length=64, description='用户名')
    password = fields.CharField(max_length=128, description='密码')
    user_type = fields.BooleanField(default=False, description='用户类型 True 超级管理员， False 普通管理员')
    create_time = fields.DatetimeField(auto_now_add=True, description='创建时间')
    update_time = fields.DatetimeField(auto_now=True, description='更新时间')

    class Meta:
        table = 'oz_user'
        table_description = '用户表'
